package 第三章作业.第二次;

import java.util.Scanner;
public class Test6 {
    public static void main(String[] args){
        System.out.println("请输入分数：");
        while(true){
            Scanner reader = new Scanner(System.in);
            double point = reader.nextDouble();
            if(point <0 || point >100){
                System.out.println("成绩输入有误，请重新输入");
                continue;
            }
            if(point > 0 && point < 60){
                System.out.println("学生成绩等级为C");
                break;
            }
            else if(point >= 60  && point < 80){
                System.out.println("学生成绩等级为B");
                break;
            }
            else if(point >= 80  && point < 100){
                System.out.println("学生成绩等级为A");
                break;
            }
        }
    }
}
